﻿using DAL;
using Model;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace BLL
{
    public class MenDian_BLL
    {
        public MenDian_BLL(MenDian_DAL dal)
        {
            Dal = dal;
        }

        public MenDian_DAL Dal { get; }

        /// <summary>
        /// 门店添加
        /// </summary>
        /// <param name="m"></param>
        /// <returns></returns>
        public int MDAdd(MenDian_Model m)
        {
           return Dal.MDAdd(m);
        }
        /// <summary>
        /// 门店列表
        /// </summary>
        /// <param name="index"></param>
        /// <param name="size"></param>
        /// <param name="MDName"></param>
        /// <param name="MDZT"></param>
        /// <param name="Count"></param>
        /// <param name="Count2"></param>
        /// <returns></returns>
        public List<MenDian_Model> MDShow(int index, int size, string? MDName, int? MDZT,out int Count,out int Count2)
        {
            
            return Dal.MDShow(index, size, MDName, MDZT,out Count,out Count2);
        }

        /// <summary>
        /// 修改状态
        /// </summary>
        /// <param name="MDid"></param>
        /// <param name="MDZT"></param>
        /// <returns></returns>
        public int MDXZT(int MDid, int MDZT)
        {
            return Dal.MDXZT(MDid, MDZT);
        }
        /// <summary>
        /// 门店反填
        /// </summary>
        /// <param name="MDid"></param>
        /// <returns></returns>
        public MenDian_Model MDFan(int MDid)
        {
            return Dal.MDFan(MDid);
        }

        /// <summary>
        /// 门店修改
        /// </summary>
        /// <param name="m"></param>
        /// <returns></returns>
        public int MDXiouGai(MenDian_Model m)
        {

            return Dal.MDXiouGai(m);
        }
    }
}
